Skip to content

Fix misleading variable name in authentication filter #17751

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

jaehwan02
Copy link

Rename DEFAULT_ANT_PATH_REQUEST_MATCHER to DEFAULT_PATH_REQUEST_MATCHER to reflect PathPatternRequestMatcher usage instead of legacy Ant pattern terminology.

Description

This PR improves code clarity by fixing a misleading variable name in UsernamePasswordAuthenticationFilter and removing outdated terminology.

Problem

The current variable DEFAULT_ANT_PATH_REQUEST_MATCHER incorrectly suggests that Ant pattern matching is being used, when the actual implementation uses PathPatternRequestMatcher. This naming inconsistency can confuse developers reading the code.

Solution

Rename the variable to DEFAULT_PATH_REQUEST_MATCHER to:

  • Accurately reflect the PathPatternRequestMatcher implementation
  • Remove misleading references to legacy Ant pattern terminology
  • Improve code readability and maintainability

Changes

  • Rename DEFAULT_ANT_PATH_REQUEST_MATCHER to DEFAULT_PATH_REQUEST_MATCHER
  • Update constructor references to use the new variable name
  • No functional changes - purely a documentation/naming improvement

Rename DEFAULT_ANT_PATH_REQUEST_MATCHER to DEFAULT_PATH_REQUEST_MATCHER
to reflect PathPatternRequestMatcher usage instead of legacy Ant
pattern terminology.

Signed-off-by: Jaehwan Lee <[email protected]>
@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label Aug 16, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: waiting-for-triage An issue we've not yet triaged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants